# -*- coding: utf-8 -*-
'''
Created on 24.12.2009

@author: r4smus
'''

from Tkinter import *

class TkWidgets(object):
    '''
    classdocs
    '''


    def __init__(self):
        '''
        Constructor
        '''
        master = Tk()
        master.title('verändern eines Labels')
        self.label = Label(master, activebackground='blue', text='ich bin ein außergewöhnliches Label', 
                           padx=5, pady=5,
                           font= ('Verdana',20,'bold'),
                           fg='green',
                           bg='red',
                           relief=GROOVE)
        self.label.pack()
        
        self.button = Button(master, text='verändere das Label', command=self.changeLabel)
        self.button.pack()
        
        self.clickState = False
        
        master.mainloop()
        
    def changeLabel(self):
        if self.clickState == False:
            self.clickState = True
            self.label.config(font= ('Corier New', 12, 'bold underline'), fg='yellow')
        else:
            self.clickState = False
            self.label.config(font= ('Verdana',20,'bold'),fg='green')
        
        
#Hauptprogramm
app = TkWidgets()

        
        
        
        